#!/bin/bash

if [ $# -ne 2 ]; then
    echo 'parameter not enough'
    exit 0
fi

if [ ! -f "./$1" ]; then
    echo 'the source file does not exists!'
    exit 0
fi

inkscape "./$1"  --export-text-to-path --export-pdf="./$1.pdf"
inkscape "./$1.pdf" -l "./$2"